1. Field of the Invention
Embodiments of the present invention generally relate to graphics processing and more specifically to using affinity masks to control multi-GPU graphics processing.
2. Description of the Related Art
Computer graphics image data typically undergoes several processing steps before each graphics frame is completely rendered for display or storage. Each processing step typically operates on graphics image data utilizing programming steps defined through an application programming interface (API), enabling the graphics application to utilize high performance hardware, such as a graphics processing unit (GPU), to execute a set of processing steps with minimal real-time supervision from a host CPU. For example, a software application executing on a host central processing unit (CPU) may use an API to program processing steps in a GPU that may perform physics, graphics rendering and other related computations. The API is typically implemented within a software driver. The software driver processes the commands received from the application and uses the result of that processing to control the GPU in a system.
Historically, computing devices have included only one GPU that was responsible for both processing graphics commands and displaying the resulting images. With only one GPU, questions about how to distribute work among multiple processing devices never really arose. By default, all such decisions have traditionally been left up to the software driver, and conventional APIs, adhering to this architectural model, provide little opportunity to the software application to assign processing work. Such an approach, however, is problematic in systems with more than one GPU, known as “multi-GPU” systems, because the software driver distributes work among the various GPUs without any domain specific knowledge, which oftentimes results in inefficient work distribution among the GPUs.
As the foregoing illustrates, what is needed in the art is a mechanism for enabling applications to have greater control over which GPUs in a multi-GPU system process specific sets of commands.